#include<iostream>
#include<assert.h>
using namespace std;
#include"list.h"
void Testlt1()
{
	dm::list<int> lt;
	lt.push_back(1);
	lt.push_back(2);
	lt.push_back(3);
	lt.push_back(4);
	lt.push_back(5);
	lt.push_back(6);
	lt.push_back(7);
	dm::list<int>::iterator it = lt.begin();
	for (auto e : lt)
	{
		cout << e << " ";
	}
	cout << endl;
	lt.pop_back();
	lt.pop_front();
	for (auto e : lt)
	{
		cout << e << " ";
	}
	cout << endl;
	lt.push_front(0);
	lt.insert(lt.begin(), 8);
	for (auto e : lt)
	{
		cout << e << " ";
	}
}
void Testlt2()
{
	dm::list<int> lt1;
	lt1.push_back(1);
	lt1.push_back(2);
	lt1.push_back(3);
	lt1.push_back(4);
	lt1.push_back(5);
	lt1.push_back(6);
	lt1.push_back(7);
	
	dm::list<int> lt2 = lt1;

	dm::list<int> lt3;
	lt3 = lt2;
	cout << "lt1: ";
	for (auto e : lt1)
	{
		cout << e << " ";
	}
	cout << endl;
	cout << "lt2: ";
	for (auto e : lt2)
	{
		cout << e << " ";
	}
	cout << endl;
	cout << "lt3: ";
	for (auto e : lt3)
	{
		cout << e << " ";
	}
	cout << endl;
	lt2.clear();
	for (auto e : lt2)
	{
		cout << e << " ";
	}
}
int main()
{
	//Testlt1();
	Testlt2();
	return 0;
}